iqbal Laravel save record in two table in one line

99

$phone = Phone::find(1);
 
$user = User::find(10);
 
$phone->user()->associate($user)->save();

Comments

Submit
0 Comments